We're going to be using R to work through the majority of the tutorials/examples in Visualize This over the course of the remainder of the semester. R is actually a pretty involved environment that caters to statisticians (which we are definitely not!) but given the thoroughness of Nathan Yau's contextualized tutorials (they are more about explaining process than teaching how to code in R) – I think working through the material and looking at it very closely will be beneficial to the class. You are only expected to be as familiar with R as reader who takes the time to do a close reading of this text – so no pressure. I'll be working through this material at the same time and I'll use this page to make notes and post links to related material.
To get started:
We are lucky in that a new—much more lay user friendly—R environment has been released in the last few years. This environment is called RStudio. Your first order of business is to install it on the machine you'll be working on – you can do that here.
You'll need to download the code and data from Nathan's book site – you can do that here. (Just grab the whole .zip archive at the very bottom of the page)
Tips within R:
You have to set your working directory to the folder associated with each tutorial. So, for Chapter 4 – in the lower right quadrant of the page, navigate to wherever you've stored the tutorials and navigate to the 'ch04' folder. Once you are there, click on 'More' on the top menu bar and select 'Set as Working Directory' – now files are being run in relation to this folder (and the nested files/resources will be available).
The top left part of the screen is where files or code are inspected, if you double click on a file or .csv in the lower right, it will open in the top left.
To run one of the example files, click on 'Source' (in the top right of the code/file inspector)
The lower left quadrant of the screen is the console – where R 'thinks' if you are just running the examples you don't need to worry about this but if you are fooling around with the code, pay attention to this area as warning messages will pop up here! (i.e. messages saying files are missing or that you've broken the code syntax).
Interested in learning how to author R scripts from the ground up? See the exercises on this page.
We're going to be using R to work through the majority of the tutorials/examples in Visualize This over the course of the remainder of the semester. R is actually a pretty involved environment that caters to statisticians (which we are definitely not!) but given the thoroughness of Nathan Yau's contextualized tutorials (they are more about explaining process than teaching how to code in R) – I think working through the material and looking at it very closely will be beneficial to the class. You are only expected to be as familiar with R as reader who takes the time to do a close reading of this text – so no pressure. I'll be working through this material at the same time and I'll use this page to make notes and post links to related material.
To get started:
Tips within R:
Interested in learning how to author R scripts from the ground up? See the exercises on this page.